import QS from 'qs'
import { axios_instance } from './config'
import store from '@/store/index';

export function cmsindex (params) {
  return axios_instance.post('cms/index', QS.stringify(params),  {
    params: {
      lang: store.getters.getLang == 'zh' ? 'zh-cn' : 'en-us'
    }
  })
}

export function saishizhongxin (params) {
  return axios_instance.post('cms/saishizhongxin', QS.stringify(params),  {
    params: {
      lang: store.getters.getLang == 'zh' ? 'zh-cn' : 'en-us'
    }
  })
}

export function huichangdaolan (params) {
  return axios_instance.post('cms/huichangdaolan', QS.stringify(params),  {
    params: {
      lang: store.getters.getLang == 'zh' ? 'zh-cn' : 'en-us'
    }
  })
}

export function yiqingchengnuo (params) {
  return axios_instance.post('cms/yiqingchengnuo', QS.stringify(params),  {
    params: {
      lang: store.getters.getLang == 'zh' ? 'zh-cn' : 'en-us'
    }
  })
}

export function shipinzhibo (params) {
  return axios_instance.post('cms/shipinzhibo', QS.stringify(params),  {
    params: {
      lang: store.getters.getLang == 'zh' ? 'zh-cn' : 'en-us'
    }
  })
}

export function xinwenzixun (params) {
  return axios_instance.post('cms/xinwenzixun', QS.stringify(params),  {
    params: {
      lang: store.getters.getLang == 'zh' ? 'zh-cn' : 'en-us'
    }
  })
}

//精彩时刻
export function jingcaishike (params) {
  return axios_instance.post('cms/jingcaishike', QS.stringify(params),  {
    params: {
      lang: store.getters.getLang == 'zh' ? 'zh-cn' : 'en-us'
    }
  })
}

//大赛合作
export function dasaihezuo (params) {
  return axios_instance.post('cms/dasaihezuo', QS.stringify(params),  {
    params: {
      lang: store.getters.getLang == 'zh' ? 'zh-cn' : 'en-us'
    }
  })
}

//公众体验
export function gongzhongtiyan (params) {
  return axios_instance.post('cms/gongzhongtiyan', QS.stringify(params),  {
    params: {
      lang: store.getters.getLang == 'zh' ? 'zh-cn' : 'en-us'
    }
  })
}

// 关于大赛
export function hezuohuoban (params) {
  return axios_instance.post('cms/hezuohuoban', QS.stringify(params),  {
    params: {
      lang: store.getters.getLang == 'zh' ? 'zh-cn' : 'en-us'
    }
  })
}

//常见问题
export function changjianwenti (params) {
  return axios_instance.post('cms/changjianwenti', QS.stringify(params),  {
    params: {
      lang: store.getters.getLang == 'zh' ? 'zh-cn' : 'en-us'
    }
  })
}

//联系我们
export function lianxiwomen (params) {
  return axios_instance.post('cms/lianxiwomen', QS.stringify(params),  {
    params: {
      lang: store.getters.getLang == 'zh' ? 'zh-cn' : 'en-us'
    }
  })
}

//论坛议程
export function luntanyicheng (params) {
  return axios_instance.post('cms/luntanyicheng', QS.stringify(params),  {
    params: {
      lang: store.getters.getLang == 'zh' ? 'zh-cn' : 'en-us'
    }
  })
}
// 论坛预约
export function luntanyvyue (params) {
  return axios_instance.post('cms/luntanyvyue', QS.stringify(params),  {
    params: {
      lang: store.getters.getLang == 'zh' ? 'zh-cn' : 'en-us'
    }
  })
}